SlkStore.SetGradingProperties Method

Stores grading-related information about an assignment into the SLK database. The user must be an instructor on the assignment.

Parent Type: SlkStore

Namespace: Microsoft.SharePointLearningKit

Assembly: Microsoft.SharePointLearningKit.dll

Syntax
C#

public string SetGradingProperties (
AssignmentItemIdentifier assignmentId,
IEnumerable<GradingProperties> gradingPropertiesList

)

Parameters

assignmentId

The AssignmentItemIdentifier of the assignment to store information about.

gradingPropertiesList

Contains one GradingProperties object for each learner assignment to update. Note that GradingProperties.LearnerId, GradingProperties.LearnerName, and GradingProperties.GradedPoints are ignored. Also, see GradingProperties.Status for information about which LearnerAssignmentState changes are permitted.

Return Value

If the operation is fully successful, null is returned. Note that data loss caused by one instructor overwriting the changes of another is considered normal behavior and is therefore treated as fully successful. If the operation is partially successul, a warning string is returned. In both the fully-successful and partially-successful cases the caller should assume that all data that could be saved to the database was saved, and if the data is to be redisplayed to the user the caller should reload the data using GetGradingProperties. If the operation fails, an exception is thrown -- in this case, the caller should assume no data was stored in the database.

Exceptions
Exception type Condition
SafeToDisplayException

An error occurred that can be displayed to a browser user. Possible cause: the user isn't an instructor on the assignment.

Remarks

Security:  Fails if the current user isn't an instructor on the assignment.